<include file="public@header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<ul class="nav nav-tabs">
			<li class="active"><a href="">已处理预约列表</a></li>
		</ul>
		<table class="table table-hover table-bordered">
			<thead>
				<tr>
					<th>ID</th>
					<th>姓名</th>
					<th>性别</th>
					<th>年龄</th>
					<th>电话</th>
					<th>身高（cm）</th>
					<th>体重（kg）</th>
					<th>症状描述</th>
					<th>预约就诊时间</th>
					<th>状态</th>
					<th>操作</th>
				</tr>
			</thead>
			<tbody>
				<empty name="data">
					<tr><td class="text-center" colspan="12">暂无任何数据！</td></tr>
					<else/>
					<foreach name="data" item="v">
						<tr>
							<td>{$v.o_id}</td>
							<td>{$v.s_name}</td>
							<td>
								<switch name="v.s_sex">
									<case value="0">
										女
									</case>
									<case value="1">
										男
									</case>
								</switch>
							</td>
							<td>{$v.s_age}</td>
							<td>{$v.s_phone}</td>
							<td>{$v.s_hight}</td>
							<td>{$v.s_weight}</td>
							<td>{$v.o_desc}</td>
							<td>{$v.o_time}</td>
							<td>								
								<if condition="$v['o_ischuli'] eq 1">
									预约已处理
								<else />
									预约已过期
								</if>
							</td>
							<td>
								<a href="javascript:void(0);" class="btn btn-info btn-xs info" data-id="{$v.o_id}">详情</a>
								<a href="javascript:void(0);" class="btn btn-info btn-xs info2" data-id="{$v.o_id}">问诊单详情</a>
							</td>
						</tr>
					</foreach>
				</empty>
			</tbody>
		</table>
		<div class="pagination">{$page}</div>
	</div>
	<script src="__STATIC__/js/admin.js"></script>
	<script src="__STATIC__/js/layer/layer.js"></script>
	<script>
		$(".info").click(function(e){
		    let id = $(e.target).attr("data-id");
		    layer.open({
				type:2,
				title:"预约信息",
				area:['600px',"80%"],
				content:"{:url('Order/read')}?id="+id
			});
		});
		$(".info2").click(function(e){
		    let id = $(e.target).attr("data-id");
		    layer.open({
				type:2,
				title:"问诊单信息",
				area:['700px',"80%"],
				content:"{:url('Order/wenzhen')}?id="+id
			});
		});


	</script>
</body>
</html>
